#pragma once

#include <openssl/md5.h>
#include "../base/types.h"


OPEN_JLIB_NS


struct MD5 {


  constexpr static uwl hash_size () noexcept {
    return 16;
  }


  inline static uwl hash (void *dst, const void *src, uwl src_size) noexcept {
    ::MD5((const u8*)src, src_size, (u8*)dst);
    return 16;
  }

};


CLOSE_JLIB_NS